package com.shunwang.caipiao.dao;

import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.ResultSet;
import java.sql.Statement;
import java.util.Properties;


public class aaa {

	public static void main(String[] args){
		try{
			
			//String url = "jdbc:odbc:Driver={Microsoft Access Driver (*.mdb, *.accdb)};DBQ=e:/netdesk/accDb/caipiao_fl.accdb";
			String url = "jdbc:odbc:cp";
			Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
			Properties p = new Properties();
			p.setProperty("charSet", "GB2312");
			Connection conn = DriverManager.getConnection(url,p);
			System.out.println(conn);
			Statement sta = conn.createStatement();
			int x = sta.executeUpdate("insert into doubleColor(sno,red_1,red_2,red_3,red_4,red_5" +
					",red_6,blue_1 values(002,1,2,3,4,5,6,7)");
//			if(resu.next()){
//				System.out.println(resu.getString("red_1"));
//			}
			System.out.println(x);
			}catch(Exception e){
				e.printStackTrace();
			}
	}
}
